package com.mini.model;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.util.Date;

/**
 * @author: zhaocg
 * @created: 2020/12/02 11:49
 */
@Data
@ApiModel(value = "业务组-业务范围表")
@Entity
@NoArgsConstructor
@AllArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
public class BusinessBelongingInfo {


    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;

    @ApiModelProperty(value = "业务组基本数据ID")
    private Long businessGroupId;

    @ApiModelProperty(value = "销售组ID")
    private Long deptId;

    @ApiModelProperty(value = "是否可用 0-可用 1-不可用")
    private Integer states;

    @ApiModelProperty(value = "操作人ID")
    private Long operatorId;

    @ApiModelProperty(value = "量子军团ID")
    private Long legionId;

    @ApiModelProperty(value = "军团ID")
    private Long armyId;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @ApiModelProperty(value = "更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    @Transient
    @ApiModelProperty(value = "显示组织名称")
    private String showOrgName;

}
